<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<title>模拟考试</title>
	<link rel="stylesheet" href="resource/exam/exam.css" type="text/css" />
	<style type="text/css">
		/*打印时，背景为白色*/
		@media print {
			body {
				font-size: 12px;
				background-color: #fff;
			}
			.div_topic {
				padding: 5px;
				border: #000 dashed;
				border-width: 0 0 1px 0;
				background-color: #fff;
			}
			.div_topic h4 {
				font-size: 14px;
				color: #000;
			}
			.div_topic h4 span {
				display: none
			}
			#answer_last {
				background-color: #eee;
				border: 1px dashed #333;
				color: #000000;
				display: block;
				position: static;
				width: auto;
				height: auto;
			}
		}
	</style>
	<script src="resource/exam/jquery.js" type="text/javascript"></script>
	<script type="text/javascript">
		var topics = <%out.print((String)request.getAttribute("onlineExamVo"));%>;
		
		
		
		$(document).ready(function() {
			var right = topics[3];
			
			$("h4 span").hide();
			
			$('input[type="radio"]').click(function(){
				if(this.value != right){
					
					$("h4 span").css("color","red");
					$("h4 span").show();
				}else{
					$("h4 span").css("color","green");
					$("h4 span").show();
				}
			});
			
			
			
			
			$('input[type="button"]').click(function(){
				var chk_value = "";
				$('input[type="checkbox"]:checked').each(function(){    
				   chk_value = chk_value + $(this).val();    
				  }); 
				if(chk_value != right){
					
					$("h4 span").css("color","red");
					$("h4 span").show();
				}else{
					$("h4 span").css("color","green");
					$("h4 span").show();
				}
			});
		});
	
	</script>
</head>
	<div id="fixedLayer">
		<div>
			<p>
				<span id="topic_right"> 
			</p>

		</div>
	</div>
	<br />
	<br />
	<br />
	<div id="topic_all">
		<%out.print((String)request.getAttribute("topics"));%>
	</div>
</body>
</html>